
package com.feib.soeasy.service.impl;

import javax.annotation.Resource;

import org.springframework.stereotype.Service;

import com.feib.soeasy.dao.MailQueueDao;
import com.feib.soeasy.model.MailQueue;
import com.feib.soeasy.service.MailQueueService;


/**
 * @title (#)MailQueueServiceImpl.java<br>
 * @description <br>
 * @author Jimmy Liu<br>
 * @version 1.0.0 2010/11/25
 * @copyright Far Eastern International Bank Copyright (c) 2010<br>
 * @2010/12/4 create by Jimmy Liu<br>
 */
@Service("mailQueueService")
public class MailQueueServiceImpl extends BaseServiceImpl implements MailQueueService {

    @Resource(name="mailQueueDao")
    private MailQueueDao mailQueueDao;
    
    /*
     * (non-Javadoc)
     * @see com.feib.soeasy.service.MailQueueService#queryByPk(java.lang.Long)
     */
    @Override
    public MailQueue queryByPk(Long mailQueuePk) {
        return mailQueueDao.findByPk(mailQueuePk);
    }

    /* (non-Javadoc)
     * @see com.feib.soeasy.service.MailQueueService#getUnSendMail()
     */
    @Override
    public MailQueue getUnSendMail() {
        return mailQueueDao.findUnSendMail();
    }

    /* (non-Javadoc)
     * @see com.feib.soeasy.service.MailQueueService#updateMailStatus(com.feib.soeasy.model.MailQueue)
     */
    @Override
    public MailQueue updateMailStatus(MailQueue mailQueue) {
        return mailQueueDao.updateMailStatus(mailQueue);
    }

}
